﻿<!doctype html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <title>ysSlider.js图片轮播插件</title>
    <link rel="stylesheet" href="static/css/animate.min.css">


    <script src="static/js/ysslider.js"></script>
    <link rel="stylesheet" href="static/css/ysslider.css" />
    <style>
        .container {
            margin: 0%;
            padding: 0%;
            position: absolute;
            width: 600px;
            height: 100%;
        }
    </style>
</head>

<body>

    <div class="container" >
 
        <div class="ysslider">
            <div class="item">
                <img src="static/image/main/0.png"/>
            </div>
            <div class="item fadeIn"><img src="static/image/main/7.png"/></div>
            <div class="item"><img src="static/image/main/5.png"/></div>
            <div class="item"><img src="static/image/main/6.png"/></div>
            <div class="controlbar">
                <a href="javascript:void(0);" class="prev">上一个</a>
                <a href="javascript:void(0);" class="next">下一个</a>
            </div>
        </div>
    </div>
    <script>
        var mySlider = new ysSlider({
            animate: true,
            touch: true
        });

        document.querySelector(".prev").onclick = function () {
            mySlider.prev();
        }

        document.querySelector(".next").onclick = function () {
            mySlider.next();
        }
    </script>
</body>
</html>
